Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TAS: Update cache on delete Topology. #3615

Merged

Conversation

mbobrovskyi
Copy link
Contributor

@mbobrovskyi mbobrovskyi commented Nov 22, 2024

What type of PR is this?

/kind bug

What this PR does / why we need it:

Fixed bug that doesn't allow to update cache on delete Topology.

Which issue(s) this PR fixes:

Fixes #3614

Special notes for your reviewer:

Does this PR introduce a user-facing change?

TAS: Fixed bug that doesn't allow to update cache on delete Topology.

@k8s-ci-robot
Copy link
Contributor

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@k8s-ci-robot k8s-ci-robot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. release-note Denotes a PR that will be considered when it comes time to generate release notes. kind/bug Categorizes issue or PR as related to a bug. labels Nov 22, 2024
@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Nov 22, 2024
@mbobrovskyi
Copy link
Contributor Author

/test all

@k8s-ci-robot k8s-ci-robot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Nov 22, 2024
Copy link

netlify bot commented Nov 22, 2024

Deploy Preview for kubernetes-sigs-kueue canceled.

Name Link
🔨 Latest commit 3c1aa99
🔍 Latest deploy log https://app.netlify.com/sites/kubernetes-sigs-kueue/deploys/6745a7140fa41400086f6cb1

@mbobrovskyi mbobrovskyi force-pushed the fix/tas-updates-or-deleted-of-topology branch 2 times, most recently from e4d259c to 667a1aa Compare November 22, 2024 15:50
@mbobrovskyi mbobrovskyi marked this pull request as ready for review November 22, 2024 15:50
@k8s-ci-robot k8s-ci-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Nov 22, 2024
@mbobrovskyi mbobrovskyi force-pushed the fix/tas-updates-or-deleted-of-topology branch 2 times, most recently from a88e3f0 to 2d1021c Compare November 22, 2024 16:08
@mimowo
Copy link
Contributor

mimowo commented Nov 25, 2024

@mbobrovskyi please split this PR into two: for delete and update. I think for delete we are almost good to go, for update I need to rethink if we need this complication. And I'm not sure about race conditions for the workload usage, so maybe we just block updating.

@mbobrovskyi mbobrovskyi changed the title TAS: Update cache on update or delete Topology. TAS: Update cache on delete Topology. Nov 25, 2024
@mimowo
Copy link
Contributor

mimowo commented Nov 25, 2024

Then, we could cherry-pick probably handling of delete.

As for updates I think it is better to block updates for now to reflect the status quo that updates are not supported. Then, we could support updates and relax validation when we are confident about the solution.

So I propose:

  1. minimal PR fix for deletes (can be cherry-picked cause deleting is broken anyway)
  2. PR to block topology updates for .spec.levels field by validation on the topology API (can be considered for cherry-picking, because updating is broken anyway)
  3. PR to relax validation for the spec.levels field to allow validation when we are confident the solution works (would be a new feature)

@mbobrovskyi mbobrovskyi force-pushed the fix/tas-updates-or-deleted-of-topology branch from 2d1021c to aba84b0 Compare November 25, 2024 08:58
@k8s-ci-robot k8s-ci-robot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Nov 25, 2024
@mbobrovskyi mbobrovskyi marked this pull request as draft November 25, 2024 09:05
@k8s-ci-robot k8s-ci-robot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Nov 25, 2024
@mbobrovskyi
Copy link
Contributor Author

/test all

@mbobrovskyi mbobrovskyi force-pushed the fix/tas-updates-or-deleted-of-topology branch from aba84b0 to a600640 Compare November 25, 2024 09:52
@k8s-ci-robot k8s-ci-robot removed the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Nov 25, 2024
@mbobrovskyi
Copy link
Contributor Author

mbobrovskyi commented Nov 25, 2024

/retest

Due to #3626

@mbobrovskyi
Copy link
Contributor Author

/test pull-kueue-test-integration-main

1/5

@mimowo
Copy link
Contributor

mimowo commented Nov 26, 2024

/test pull-kueue-test-integration-main

2/5

@mimowo
Copy link
Contributor

mimowo commented Nov 26, 2024

/test pull-kueue-test-integration-main

3/5

@mbobrovskyi
Copy link
Contributor Author

/test pull-kueue-test-integration-main

4/5

@mbobrovskyi
Copy link
Contributor Author

/test pull-kueue-test-integration-main

5/5

@mbobrovskyi mbobrovskyi force-pushed the fix/tas-updates-or-deleted-of-topology branch from 3c8e77f to 3c1aa99 Compare November 26, 2024 10:46
Copy link
Contributor

@mimowo mimowo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Nov 26, 2024
@k8s-ci-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 4a3c79fd9b4b895e4e23eea39130ce4ce232e5ee

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: mbobrovskyi, mimowo

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Nov 26, 2024
@mimowo
Copy link
Contributor

mimowo commented Nov 26, 2024

/cherry-pick release 0.9

@k8s-infra-cherrypick-robot
Copy link
Contributor

@mimowo: once the present PR merges, I will cherry-pick it on top of release in a new PR and assign it to you.

In response to this:

/cherry-pick release 0.9

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@k8s-ci-robot k8s-ci-robot merged commit 998d17c into kubernetes-sigs:main Nov 26, 2024
17 checks passed
@k8s-ci-robot k8s-ci-robot added this to the v0.10 milestone Nov 26, 2024
@k8s-infra-cherrypick-robot
Copy link
Contributor

@mimowo: cannot checkout release: error checking out "release": exit status 1 error: pathspec 'release' did not match any file(s) known to git

In response to this:

/cherry-pick release 0.9

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@mbobrovskyi mbobrovskyi deleted the fix/tas-updates-or-deleted-of-topology branch November 26, 2024 11:19
@mimowo
Copy link
Contributor

mimowo commented Nov 26, 2024

/cherry-pick release-0.9

@k8s-infra-cherrypick-robot
Copy link
Contributor

@mimowo: #3615 failed to apply on top of branch "release-0.9":

Applying: TAS: Update cache on delete Topology.
Using index info to reconstruct a base tree...
M	pkg/cache/tas_flavor.go
M	pkg/controller/tas/resource_flavor.go
Falling back to patching base and 3-way merge...
Auto-merging pkg/controller/tas/resource_flavor.go
CONFLICT (content): Merge conflict in pkg/controller/tas/resource_flavor.go
Auto-merging pkg/cache/tas_flavor.go
CONFLICT (content): Merge conflict in pkg/cache/tas_flavor.go
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
hint: When you have resolved this problem, run "git am --continue".
hint: If you prefer to skip this patch, run "git am --skip" instead.
hint: To restore the original branch and stop patching, run "git am --abort".
hint: Disable this message with "git config advice.mergeConflict false"
Patch failed at 0001 TAS: Update cache on delete Topology.

In response to this:

/cherry-pick release-0.9

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@mimowo
Copy link
Contributor

mimowo commented Nov 26, 2024

@mbobrovskyi can you check what are the conflicts and prepare manual cherry-pick if nothing serious?

@mbobrovskyi
Copy link
Contributor Author

@mbobrovskyi can you check what are the conflicts and prepare manual cherry-pick if nothing serious?

We should cherry-pick #3509 first.

k8s-ci-robot pushed a commit that referenced this pull request Nov 26, 2024
#3615: TAS: Update cache on delete Topology. (#3655)

* Use TopologyReference instead of string.

* TAS: Update cache on delete Topology.

* Add sleep one second to be sure cache updated.

* Fix scheduler_test.go.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/bug Categorizes issue or PR as related to a bug. lgtm "Looks good to me", indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

TAS: Updates or deletion of Topology is not reflected in TAS cache resulting in wrong admission
4 participants